<script lang="ts" setup name="Detail">
    import { toRefs } from 'vue';
    import { useRoute } from 'vue-router';

    let route = useRoute();
    let {query} = toRefs(route);  // 解构
</script>

<template>
    <div>
        <h2>编号：{{ query.id }}</h2>
        <h2>标题：{{ query.title }}</h2>
        <h2>内容：{{ query.content }}</h2>
    </div>
</template>